Carbon


EqualString

Header: StringCompare.h Carbon status: Supported

Compares two Pascal strings for equality, using the comparison rules of the Macintosh file system. This is a simple, character-by-character value comparison.

Boolean EqualString (
    ConstStr255Param str1, 
    ConstStr255Param str2, 
    Boolean caseSensitive, 
    Boolean diacSensitive
);
Parameter descriptions
str1

One of the Pascal strings to be compared.

str2

The other Pascal string to be compared.

caseSensitive

A flag that indicates how to handle case-sensitive information during the comparison. If the value of caseSens is TRUE, uppercase characters are distinguished from the corresponding lowercase characters. If it is FALSE, case information is ignored.

diacSensitive

A flag that indicates how to handle information about diacritical marks during the string comparison. If the value of diacSens is TRUE, characters with diacritical marks are distinguished from the corresponding characters without diacritical marks during the comparison. If it is FALSE, diacritical marks are ignored.

function result

TRUE if the two strings are equal and FALSE if they are not equal. If its value is TRUE, EqualString distinguishes uppercase characters from the corresponding lowercase characters. If its value is FALSE, EqualString ignores diacritical marks during the comparison.

DISCUSSION

This function does not make use of any script or language information (i.e., is not localizable); it assumes the use of a Roman script system.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)